package com.zhoug.commonlib2.notifycation;

import android.os.Bundle;
import android.widget.Button;

import com.zhoug.commonlib2.MyBaseActivity;
import com.zhoug.commonlib2.R;

/**
 * @Author: zhoug
 * @Date: 2024-11-16
 * @Description:
 */
public class TestNotificationActivity extends MyBaseActivity {
    private Button mBtnNotifycation;
    private Button mBtnDetail;
    private Button mBtnCloseNotifycation;
    private Button mBtnNotifycationClose;

    @Override
    protected int getLayoutResId() {
        return R.layout.activity_test_notification;
    }

    @Override
    protected void findViews() {

        mBtnNotifycation = findViewById(R.id.btn_notifycation);
        mBtnDetail = findViewById(R.id.btn_detail);
        mBtnCloseNotifycation = findViewById(R.id.btn_closeNotifycation);
        mBtnNotifycationClose = findViewById(R.id.btn_notifycationClose);
    }

    @Override
    protected void onCreate1(Bundle savedInstanceState) {
        mBtnNotifycation.setOnClickListener(v -> {
            MyTaskService.start(this);
        });
        mBtnNotifycationClose.setOnClickListener(v->{
            MyTaskService.stop(this);
        });
        mBtnCloseNotifycation.setOnClickListener(v->{
            MyForeService.stop(this);
        });

        mBtnDetail.setOnClickListener(v -> {
            toActivity(DetailActivity.class);
        });
    }

}
